package ArrayTest.Homework.ArmyTest;

public class Tank extends Weapon implements Attack  {
    public Tank(){

    }
    public Tank(String name, String type){
        this.name = name;
        this.type = type;
    }
    public void attack(){
        System.out.println(this.name+"开炮开炮！");
    }

    @Override
    public String toString() {
        return "Tank{" +
                "name='" + name + '\'' +
                ", type='" + type + '\'' +
                '}';
    }
}
